let express = require('express');

let uploadBusiness = require('../business/upload');

let router = module.exports = express.Router();

/**
 * upload file to qiniu
 */
// form parser
router.post('/', uploadBusiness.formParser);
// check input
router.post('/', uploadBusiness.checkInput);
// upload file to qiniu
router.post('/', uploadBusiness.uploadFile);
// store upload record in the db.
router.post('/', uploadBusiness.storeRecord);